import type { IArticleCate, IArticles } from "@/types/articles"
import httpReq from "@/utils/request"

// 获取文章分类列表
export const getArtCateApi = () => {
    return httpReq<IArticleCate[]>('/article/cates')
}

// 根据id获取文章列表
export const getArticlesApi = (id: number) => {
    return httpReq<IArticles[]>(`/article/get/${id}`)
}